home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Columbia Kermit
/
kermit.zip
/
newsgroups
/
misc.19981211-19990422
/
000399_news@watsun.cc.columbia.edu _Mon Mar 22 13:46:00 1999.msg
< prev
next >
Wrap
Internet Message Format
|
2020-01-01
|
3KB
Return-Path: <news@watsun.cc.columbia.edu>
Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.59.30])
by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id NAA04791
for <kermit.misc@watsun.cc.columbia.edu>; Mon, 22 Mar 1999 13:45:59 -0500 (EST)
Received: (from news@localhost)
by newsmaster.cc.columbia.edu (8.8.5/8.8.5) id NAA11058
for kermit.misc@watsun.cc.columbia.edu; Mon, 22 Mar 1999 13:30:20 -0500 (EST)
X-Authentication-Warning: newsmaster.cc.columbia.edu: news set sender to <news> using -f
From: fdc@watsun.cc.columbia.edu (Frank da Cruz)
Subject: Re: modem pool
Date: 22 Mar 1999 18:30:13 GMT
Organization: Columbia University
Message-ID: <7d627l$apd$1@newsmaster.cc.columbia.edu>
To: kermit.misc@watsun.cc.columbia.edu
In article <7d5r06$kgv$1@user2.teleport.com>,
Tony R. Bennett <trb@user2.teleport.com> wrote:
: Platform: C-kermit 6.0 running on AIX 4.3.1
:
: Has anyone created a kermrc file that will perform a 'set line' command
: from a 'pool' of ports...???
:
It's very easy, but first you have to know the names of the ports in the
pool. Then just do:
set line /dev/tty01
if success goto ok
set line /dev/tty02
if success goto ok
...
:OK
Of course you can also get the device names from a file:
set modem type generic ; Specify some kind of modem
open read xxx ; Where xxx is the filename
if fail stop 1 Can't open devices file
while true {
read devname
if fail break
echo Trying \m(devname)...
set line \m(devname)
if success goto ok
}
close read
stop 1 No devices are available - try again later
:OK
set speed 57600 ; Have device - set it up.
To be even fancier, you can read the UUCP Devices file and parse it to
get the device name, speed, and modem type. Left as an exercise to the
reader :-) (Feel free to post. But note that these files tend to vary
in format from platform to platform, version to verion).
: If not (I can do it from a script) is there a way to from within Kermit
: to run a UNIX 'script' and capture the UNIX script's output and use it
: as the device in a 'set line' command ???
:
You can do that too in C-Kermit 7.0:
http://www.columbia.edu/kermit/ck70.html
The new functions \fcommand(unix-command) and \frcommand(unix-command)
return the output from the UNIX command supplied as an argument. See
the ckermit2.txt file that comes with C-Kermit 7.0 (currently in Beta test)
for details.
- Frank